//
//  BaseViewController.h
//  HouseAgent
//
//  Created by 杨洋 on 14-10-26.
//  Copyright (c) 2014年 com.yy. All rights reserved.
//

#import "CustomViewController.h"

typedef NS_ENUM(NSInteger, RefreshType)
{
    HeaderType = 0,
    FooterType = 1,
    AllType = 2
};

@interface BaseViewController : CustomViewController<UITableViewDataSource,UITableViewDelegate,UIAlertViewDelegate,UITextFieldDelegate,UITextViewDelegate>
{
    UIStoryboard *mainStoryboard;
}

-(void)removeAllSubViews:(UIView *)view;

//添加上拉刷新 下拉加载
- (void)setupRefresh:(UITableView *)tableView type:(RefreshType)num;

- (void)headerRereshing;

- (void)footerRereshing;

-(CGSize)returnTextSize:(NSString *)text and:(CGFloat)width andF:(UIFont *)font;
-(CGSize)returnTextSize:(NSString *)text and:(CGFloat)width andF:(UIFont *)font andPar:(CGFloat)spacing;

- (BOOL)checkTel:(NSString *)str;

-(BOOL)checkIdCardNum:(NSString *)str;

-(void)toLoginVC;

//-(id)toLeaveMessageVC;

-(NSString *)timeFormatter:(double)secStr andFormatterStr:(NSString *)formatterStr;

-(NSString *)time:(NSDate *)date andFormatterStr:(NSString *)formatterStr;

-(NSString *)getNowDateString;

-(void)initMutDicAndArray;

-(void)initViews;

-(void)setExtraCellLineHidden: (UITableView *)tableView;

-(UIView *)createNoDataTipView;

-(NSString *)removeSpaceWithString:(NSString *)string;


@end
